home *** CD-ROM | disk | FTP | other *** search
- <%@ Language=VBScript CODEPAGE=65001 %>
- <!--#include file="include/wmsLocStrings.inc"-->
- <!--#include file="include/wmsServerHash.inc"-->
- <!--#include file="include/wmsPlugins.inc"-->
- <!--#include file="include/wmsHeader.inc"-->
- <!--#include file="include/wmsPageBanner.inc"-->
- <!--#include file="include/wmsError.inc"-->
- <!--#include file="plugin_loading.inc"-->
- <%
- '+-------------------------------------------------------------------------
- '
- ' Microsoft Windows Media
- ' Copyright (C) Microsoft Corporation. All rights reserved.
- '
- ' File: ActiveScript.asp
- '
- ' Contents:
- '
- '--------------------------------------------------------------------------
-
- BeginErrorHandling
- ConnectToPlugin
- ConnectToPluginAdmin
-
- Dim bError
- Dim strFileName
- Dim dwErrorLine
- Dim dwErrorPos
- Dim strErrorText
- Dim dwTabIndex
-
- dwTabIndex = 0
- bError = FALSE
-
- HandlePluginLoadingChanges()
-
- Dim strOp
- strOp = trim( posting( "submit" ) )
- if( 0 < Len( strOp ) ) then
-
- on error resume next
-
- '---------------------------------------------------------------
- ' enable debugging set, if "enableDebugging" is defined in request form
- '---------------------------------------------------------------
- if ( 0 = StrComp( "on", trim( posting("enableDebugging") ), vbTextCompare ) ) then
- if( not g_objPluginAdmin.EnableDebugging ) then
- g_objPluginAdmin.EnableDebugging = TRUE
- end if
- else
- if( g_objPluginAdmin.EnableDebugging ) then
- g_objPluginAdmin.EnableDebugging = FALSE
- end if
- end if
-
- if( ErrorDetected( "enableDebugging" ) ) then
- bError = TRUE
- end if
-
- '---------------------------------------------------------------
- ' fileName set, if "fileName" is defined in the request form
- '---------------------------------------------------------------
-
- Dim strNewFileName
- strNewFileName = CStr( SafeUnescape( trim( posting( "fileName" ) ) ) )
-
- if ( 0 >= Len( strNewFileName ) ) then
- if( 0 < Len( g_objPluginAdmin.fileName ) ) then
- g_objPluginAdmin.fileName = ""
- end if
- else
- on error resume next
- if( 0 <> StrComp( strNewFileName, g_objPluginAdmin.fileName, vbTextCompare ) ) then
- if( MAX_PATH >= Len( strNewFileName ) ) then
- g_objPluginAdmin.fileName = strNewFileName
- end if
- end if
- end if
-
- if( ErrorDetected( "fileName" ) ) then
- Session( "PageReloadedToDisplayError" ) = 1
- bError = TRUE
- else
- szExtraArgs = "&pendingOp=" & GetPostOrQsVal("pendingOp")
- if( "" <> g_strPubPointName ) then
- Response.Redirect "../pubpoints/pubpoint_props.asp?server=" & g_strQueryStringServer & "&ppID=" & g_strPubPointID & "&category=" & g_strCategory & "&pluginIndex=" & qs("pluginIndex") & szExtraArgs
- else
- Response.Redirect "../server_props.asp?server=" & g_strQueryStringServer & "&category=" & g_strCategory & "&pluginIndex=" & qs("pluginIndex") & szExtraArgs
- end if
- end if
- end if
-
- if not bError then
- strFileName = g_objPluginAdmin.FileName
- dwErrorLine = g_objPluginAdmin.ErrorLineNumber
- dwErrorPos = g_objPluginAdmin.ErrorCharacterPosition
- strErrorText = g_objPluginAdmin.ErrorText
- end if
-
- WriteHTMLHeader( g_strDecodedServerName )
- %>
- <link rel="stylesheet" type="text/css" href="<%= Session( "cssName" ) %>">
- <% WritePluginJSUtils %>
- </head>
- <body bgcolor="#FFFFFF" class="pluginBody" onLoad="JavaScript:AcquireInitialFilename();" oncontextmenu="JavaScript:event.cancelBubble=true;return false;">
- <% DrawPluginBanner %>
- <table width="<%= Server.HTMLEncode( STDTABLEWIDTH ) %>" cols=2 border="0">
- <tr>
- <td valign=top>
-
- <% WriteStdPluginForm %>
-
- <div class="normal">
-
- <p>
- </div>
-
- <table cellspacing="0" border="0" class="propgroupbox" width="100%">
- <caption align="left" class="pluginGroupHeader"><% RenderWithErrorCheck Server.HTMLEncode( L_FILENAMEOFSCRIPTCOLON_TEXT ) & "<br>", "fileName" %></caption>
- <tr><td>
- <input
- type="text"
- id="fileName"
- name="fileName"
- size="50%"
- maxlength="<%= Server.HTMLEncode( MAX_PATH ) %>"
- tabindex="1" value="<%= RemoveSpecifiedChars( strFileName, REGEXP_DANGEROUS_CHARS ) %>">
- </td></tr></table>
- <br>
- <table border=1 cellspacing="0" cellpadding="0" width="100%">
- <caption align="left" class="pluginGroupHeader"><%= Server.HTMLEncode( L_DEBUGGINGINFO_TEXT ) %></caption>
- <tr>
- <td>
- <table cellspacing="0" cellpadding="0" border="0" width="100%" class="propgroupbox">
- <tr>
- <td width="10" ><img src="img\spacer_.gif" height="1px" width="10px"></td>
- <td width="100%">
- <input type="checkbox" id="enableDebugging" name="enableDebugging" tabindex=2 <%
- if g_objPluginAdmin.EnableDebugging then
- Response.Write( "checked" )
- end if
- %> >
- <label class="handcursor" for="enableDebugging"><% RenderWithErrorCheck Server.HTMLEncode( L_ENABLESCRIPTDEBUGGING_TEXT ) & "<br>", "enableDebugging" %></label>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- <br>
- <table border=1 cellspacing="0" cellpadding="0" width="100%" class="propgroupbox">
- <caption align="left" class="pluginGroupHeader"><%= Server.HTMLEncode( L_LASTSCRERRINFO_TEXT ) %></caption>
- <tr>
- <td><br>
- <table cellspacing="0" cellpadding="0" cols="3" border="0" width="100%">
- <tr>
- <td width="10" ><img src="img\spacer_.gif" height="1px" width="10px"></td>
- <td>
- <div class="defaultcursor">
- <%= SpacesToNonbreak( L_LINENUMBERCOLON_TEXT ) %>
- </div>
- </td>
- <td width=20% align="right">
- <table cellspacing="0" cellpadding="0" border=1 bgcolor="<% if 0 <> dwErrorLine then %>white<% else %>lightgrey<% end if %>">
- <tr>
- <td>
- <% if 0 <> dwErrorLine then %> <%= Server.HTMLEncode( dwErrorLine ) %> <% else %> <%= Server.HTMLEncode( L_NA_TEXT ) %> <% end if %>
- </td>
- </tr>
- </table>
- </td>
- <td align="right">
- <img src="img\spacer_.gif" height="1px" width="10px">
- </td>
- </tr>
- <tr>
- <td width="10" ><img src="img\spacer_.gif" height="1px" width="10px"></td>
- <td>
- <div class="defaultcursor">
- <%= SpacesToNonbreak( Server.HTMLEncode( L_CHARACTERCOLUMNCOLON_TEXT ) ) %>
- </div>
- </td>
- <td width=20% align="right">
- <table cellspacing="0" cellpadding="0" border=1 bgcolor="<% if 0 <> dwErrorPos then %>white<% else %>lightgrey<% end if %>">
- <tr>
- <td>
- <% if 0 <> dwErrorPos then %> <%= Server.HTMLEncode( dwErrorPos ) %> <% else %> <%= Server.HTMLEncode( L_NA_TEXT ) %> <% end if %>
- </td>
- </tr>
- </table>
- </td>
- <td align="right">
- <img src="img\spacer_.gif" height="1px" width="10px">
- </td>
- </tr>
- <tr>
- <td width="10" ><img src="img\spacer_.gif" height="1px" width="10px"></td>
- <td>
- <div class="defaultcursor">
- <%= SpacesToNonbreak( Server.HTMLEncode( L_MOSTRECENTERRORCOLON_TEXT ) ) %>
- </div>
- </td>
- <td width="20%" align="right">
- <table cellspacing="0" cellpadding="0" border=1 bgcolor="<% if 0 < Len( strErrorText ) then %>white<% else %>lightgrey<% end if %>">
- <tr>
- <td>
- <% if 0 < Len( strErrorText ) then %><%= Server.HTMLEncode( strErrorText ) %><% else %> <%= Server.HTMLEncode( L_NA_TEXT ) %> <% end if %>
- </td>
- </tr>
- </table>
- </td>
- <td align="right">
- <img src="img\spacer_.gif" height="1px" width="10px">
- </td>
- </tr>
- <tr>
- <td colspan=3>
-
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td>
- <% dwTabIndex = 2 %>
- <% RenderPluginLoadingOptions() %>
- </td>
- </tr>
- <tr>
- <td valign="bottom">
- <br>
- <input type="submit" align="baseline" name="ok" <% if 0 <> ( WMS_PLUGIN_ENABLED and g_objPlugin.status ) then %>onclick="JavaScript:ResetWarning();"<% end if%> value="<%= Server.HTMLEncode( L_OKAYBUTTON_TEXT ) %>" tabIndex=<%= dwTabIndex + 1 %> >
- <input type="button" align="baseline" name="cancel" onclick="JavaScript:Cancel()" value="<%= Server.HTMLEncode( L_CANCELBUTTONSPACED_TEXT ) %>" tabIndex=<%= dwTabIndex + 2 %>>
- <input type="button" align="baseline" name="help" onclick="JavaScript:DoPluginHelp( '<%= H_ACTIVESCRIPTHELPTOPIC %>' )" value="<%= Server.HTMLEncode( L_HELPBUTTONSPACED_TEXT ) %>" id="help" tabindex=<%= dwTabIndex + 3 %>>
- </td>
- </tr>
- </table>
- </font>
- </form>
- <%
- AlertUserWithPopupErrorDialog
- OnErrorGoBack
- DrawStdFooter
- %>
- </body>
- <script language="JavaScript">
- <!--
- /*@cc_on @*/
-
- var g_strOriginalFilename;
-
- ///////////////////////////////////////////////////////////////////////
- function AcquireInitialFilename()
- {
- <% jsTRY %>
- var objInput;
- objInput = document.forms.pluginForm.fileName;
- g_strOriginalFilename = new String( objInput.value );
- <% jsCATCH %>
- }
-
- ///////////////////////////////////////////////////////////////////////
- function ResetWarning()
- {
- <% jsTRY %>
- var strNewFileName = new String( document.forms.pluginForm.fileName.value );
- if( strNewFileName.toLowerCase() != g_strOriginalFilename.toLowerCase() )
- {
- window.alert( "<%= RemoveDangerousCharacters( L_RESETPLUGINWARN_TEXT ) %>" );
- }
- else
- {
- var objCheckbox = document.forms.pluginForm.enableDebugging;
- var bChecked = objCheckbox.checked;
- if( bChecked != <% if g_objPluginAdmin.EnableDebugging then %>true<% else %>false<% end if %> )
- {
- window.alert( "<%= RemoveDangerousCharacters( L_RESETPLUGINWARN_TEXT ) %>" );
- }
- }
- <% jsCATCH %>
- }
- -->
- </script>
- </html>
- <%
- LatchCurrentPage "plugins/ActiveScript.asp", qs
- EndErrorHandling "ActiveScript.asp"
-
- on error resume next
- PluginsASPCleanup
- %>
-